/**
 * @Description
 */

public class Student implements Comparable<Student>{

    public String name;
    int age;
    String classRoom;

    public Student(String name, int age, String classRoom) {
        this.name = name;
        this.age = age;
        this.classRoom = classRoom;
    }

        @Override
        public int compareTo(Student o) {
            return this.age-o.age;
        }

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", age=" + age +
                ", classRoom='" + classRoom + '\'' +
                '}';
    }
}

